package com.sapitest.imp.dao;

import com.sapitest.imp.model.DeviceInfo;
import com.sapitest.keywords.JSONOperation;
import lombok.Data;

import java.util.HashMap;
import java.util.Map;

@Data
public class MyShoppingTrolley {
    private String version;
    private String countryCode;
    private String lang;
    private long pageindex;
    private long pagesize;
    private DeviceInfo devicesInfo;

    public String toJSONString(){
        Map<String, Object> map = new HashMap<>();
        map.put("version", getVersion());
        map.put("countryCode", getCountryCode());
        map.put("lang", getLang());
        map.put("pageindex", getPageindex());
        map.put("pagesize", getPagesize());
        map.put("deviceInfo", getDevicesInfo());
        return JSONOperation.parseObjectString(map);
    }
}
